<?php

//Manage the request data
$entity = get_entity(get_input('o'));

if($entity->guid)
{
	if($entity->delete("Delete from admin"))
	{
		system_message(elgg_echo('organizations:deletion:success'));
	}
	else
	{
		register_error(elgg_echo('organizations:deletion:fail'));		
	}
}
else 
{
	register_error(elgg_echo('organizations:not_found'));
}
forward('/admin/organizations/list');
